Skip to content

Filter internal backlog entries from search#81

Merged
VatsalSy merged 2 commits intomainfrom
fix/search-filter-internal-backlog
Mar 31, 2026
Merged

Filter internal backlog entries from search#81
VatsalSy merged 2 commits intomainfrom
fix/search-filter-internal-backlog

Conversation

@VatsalSy
Copy link
Copy Markdown
Member

Summary

  • filter internal Private-ToDo and 0_ToDo search entries before Fuse initialization
  • keep the fix local to the website frontend instead of modifying the generated search_db artifact
  • add a regression test covering the leaked backlog URLs

Evidence

  • commit fcfcf1b5563251037b48e05019bbb8019690aef9 updated only assets/js/search_db.json
  • that refreshed index now contains 14 public-search hits for internal backlog pages such as https://blogs.comphy-lab.org/Private-ToDo-Blog-public/ and https://blogs.comphy-lab.org/0_ToDo-Blog-public/
  • assets/js/search-manager.js previously loaded the raw JSON without any client-side filtering

Validation

  • npm test -- search-manager.test.js --runInBand
  • npm test -- command-palette-stale-search.test.js --runInBand
  • npx eslint assets/js/search-manager.js tests/search-manager.test.js

Filter search index entries that expose internal blog backlog pages through the public command palette. Add a regression test covering Private-ToDo and 0_ToDo URLs so future search_db refreshes do not resurface those links.
Copilot AI review requested due to automatic review settings March 30, 2026 17:02
@VatsalSy VatsalSy added the codex label Mar 30, 2026
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6fa4b7bdc9

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Filters internal backlog entries (e.g., Private-ToDo / 0_ToDo) out of the client-side search database before Fuse.js is initialized, preventing accidental exposure via public search results.

Changes:

  • Add client-side sanitization in SearchManager.loadSearchDatabase() to remove internal backlog entries.
  • Add a Jest regression test to ensure internal backlog URLs are excluded from loaded search data.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
assets/js/search-manager.js Adds pattern-based filtering of internal backlog entries during search DB load.
tests/search-manager.test.js Adds a regression test asserting internal backlog entries are removed.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@VatsalSy VatsalSy merged commit 2c76a00 into main Mar 31, 2026
3 checks passed
@VatsalSy VatsalSy deleted the fix/search-filter-internal-backlog branch March 31, 2026 22:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants